import request from '@/utils/request'

const clientUserLogin = (data: any) => {
  return request({
    url: '/client-user/wechatLogin',
    type: 'post',
    data
  })
}

//手机号登录
const registerPhone = (data: any) => {
  return request({
    url: '/client-user/register',
    type: 'post',
    data,
    qs: true
  })
}
//用户信息
const clientUserInfo = () => {
  return request({
    url: '/client-user/getUserInfo',
    type: 'get'
  })
}

// 修改昵称
const upUserInfo = (data: any) => {
  return request({
    url: '/client-user/upd',
    type: 'post',
    data,
    qs: true
  })
}
// 获取二维码code
const getQrCode = (data: any) => {
  return request({
    url: '/client-user/getQrCode',
    type: 'get',
    data
  })
}
export { clientUserLogin, clientUserInfo, registerPhone, upUserInfo, getQrCode }
